package com.jvm.simulation.hotspot;

import com.jvm.simulation.hotspot.attributes.AttributeInfo;
import com.jvm.simulation.hotspot.bytecode.BytecodeStream;
import lombok.Data;

import java.util.HashMap;
import java.util.Map;

@Data
public class CodeAttribute {

    int attributeNameIdx;

    String attributeName;

    int attributeLength;

    int maxStack;

    int maxLocals;

    int codeLength;

    int exceptionTableLength;

    // 如局部变量表、操作数栈
    int attributesCount;

    BytecodeStream code;

    Map<String, AttributeInfo> attributes = new HashMap<>();

    @Override
    public String toString() {
        return "CodeAttributeInfo{}";
    }

}
